#!/bin/sh

PID="com.veeho.sdlterminal"
APP_DIR="/media/cryptofs/apps"
INSTALL_DIR="$APP_DIR/usr/palm/applications/$PID"

if [ ! -d "$APP_DIR" ]; then
   echo "Requires webOS 1.4.5 or later."
   exit 1;
fi

if [ ! -d "$INSTALL_DIR" ]; then
   echo "Please install $PID first."
   exit 1;
fi

chdir "$INSTALL_DIR"
./sdlterminal
cd -
